3.1.63 \(\int \frac {(a+b \log (c (d+e x)^n))^4}{(f+g x)^2} \, dx\) [63]

Optimal. Leaf size=248 \[ \frac {(d+e x) \left (a+b \log \left (c (d+e x)^n\right )\right )^4}{(e f-d g) (f+g x)}-\frac {4 b e n \left (a+b \log \left (c (d+e x)^n\right )\right )^3 \log \left (\frac {e (f+g x)}{e f-d g}\right )}{g (e f-d g)}-\frac {12 b^2 e n^2 \left (a+b \log \left (c (d+e x)^n\right )\right )^2 \text {Li}_2\left (-\frac {g (d+e x)}{e f-d g}\right )}{g (e f-d g)}+\frac {24 b^3 e n^3 \left (a+b \log \left (c (d+e x)^n\right )\right ) \text {Li}_3\left (-\frac {g (d+e x)}{e f-d g}\right )}{g (e f-d g)}-\frac {24 b^4 e n^4 \text {Li}_4\left (-\frac {g (d+e x)}{e f-d g}\right )}{g (e f-d g)} \]

[Out]

(e*x+d)*(a+b*ln(c*(e*x+d)^n))^4/(-d*g+e*f)/(g*x+f)-4*b*e*n*(a+b*ln(c*(e*x+d)^n))^3*ln(e*(g*x+f)/(-d*g+e*f))/g/
(-d*g+e*f)-12*b^2*e*n^2*(a+b*ln(c*(e*x+d)^n))^2*polylog(2,-g*(e*x+d)/(-d*g+e*f))/g/(-d*g+e*f)+24*b^3*e*n^3*(a+
b*ln(c*(e*x+d)^n))*polylog(3,-g*(e*x+d)/(-d*g+e*f))/g/(-d*g+e*f)-24*b^4*e*n^4*polylog(4,-g*(e*x+d)/(-d*g+e*f))
/g/(-d*g+e*f)

________________________________________________________________________________________

Rubi [A]
time = 0.16, antiderivative size = 248, normalized size of antiderivative = 1.00, number of steps used = 6, number of rules used = 6, integrand size = 24, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.250, Rules used = {2444, 2443, 2481, 2421, 2430, 6724} \begin {gather*} \frac {24 b^3 e n^3 \text {PolyLog}\left (3,-\frac {g (d+e x)}{e f-d g}\right ) \left (a+b \log \left (c (d+e x)^n\right )\right )}{g (e f-d g)}-\frac {12 b^2 e n^2 \text {PolyLog}\left (2,-\frac {g (d+e x)}{e f-d g}\right ) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{g (e f-d g)}-\frac {24 b^4 e n^4 \text {PolyLog}\left (4,-\frac {g (d+e x)}{e f-d g}\right )}{g (e f-d g)}-\frac {4 b e n \log \left (\frac {e (f+g x)}{e f-d g}\right ) \left (a+b \log \left (c (d+e x)^n\right )\right )^3}{g (e f-d g)}+\frac {(d+e x) \left (a+b \log \left (c (d+e x)^n\right )\right )^4}{(f+g x) (e f-d g)} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(a + b*Log[c*(d + e*x)^n])^4/(f + g*x)^2,x]

[Out]

((d + e*x)*(a + b*Log[c*(d + e*x)^n])^4)/((e*f - d*g)*(f + g*x)) - (4*b*e*n*(a + b*Log[c*(d + e*x)^n])^3*Log[(
e*(f + g*x))/(e*f - d*g)])/(g*(e*f - d*g)) - (12*b^2*e*n^2*(a + b*Log[c*(d + e*x)^n])^2*PolyLog[2, -((g*(d + e
*x))/(e*f - d*g))])/(g*(e*f - d*g)) + (24*b^3*e*n^3*(a + b*Log[c*(d + e*x)^n])*PolyLog[3, -((g*(d + e*x))/(e*f
 - d*g))])/(g*(e*f - d*g)) - (24*b^4*e*n^4*PolyLog[4, -((g*(d + e*x))/(e*f - d*g))])/(g*(e*f - d*g))

Rule 2421

Int[(Log[(d_.)*((e_) + (f_.)*(x_)^(m_.))]*((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.))/(x_), x_Symbol] :> Simp
[(-PolyLog[2, (-d)*f*x^m])*((a + b*Log[c*x^n])^p/m), x] + Dist[b*n*(p/m), Int[PolyLog[2, (-d)*f*x^m]*((a + b*L
og[c*x^n])^(p - 1)/x), x], x] /; FreeQ[{a, b, c, d, e, f, m, n}, x] && IGtQ[p, 0] && EqQ[d*e, 1]

Rule 2430

Int[(((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)*PolyLog[k_, (e_.)*(x_)^(q_.)])/(x_), x_Symbol] :> Simp[PolyLo
g[k + 1, e*x^q]*((a + b*Log[c*x^n])^p/q), x] - Dist[b*n*(p/q), Int[PolyLog[k + 1, e*x^q]*((a + b*Log[c*x^n])^(
p - 1)/x), x], x] /; FreeQ[{a, b, c, e, k, n, q}, x] && GtQ[p, 0]

Rule 2443

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_)/((f_.) + (g_.)*(x_)), x_Symbol] :> Simp[Log[e*((
f + g*x)/(e*f - d*g))]*((a + b*Log[c*(d + e*x)^n])^p/g), x] - Dist[b*e*n*(p/g), Int[Log[(e*(f + g*x))/(e*f - d
*g)]*((a + b*Log[c*(d + e*x)^n])^(p - 1)/(d + e*x)), x], x] /; FreeQ[{a, b, c, d, e, f, g, n, p}, x] && NeQ[e*
f - d*g, 0] && IGtQ[p, 1]

Rule 2444

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_)/((f_.) + (g_.)*(x_))^2, x_Symbol] :> Simp[(d + e
*x)*((a + b*Log[c*(d + e*x)^n])^p/((e*f - d*g)*(f + g*x))), x] - Dist[b*e*n*(p/(e*f - d*g)), Int[(a + b*Log[c*
(d + e*x)^n])^(p - 1)/(f + g*x), x], x] /; FreeQ[{a, b, c, d, e, f, g, n}, x] && NeQ[e*f - d*g, 0] && GtQ[p, 0
]

Rule 2481

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_.)*((f_.) + Log[(h_.)*((i_.) + (j_.)*(x_))^(m_.)]*
(g_.))*((k_.) + (l_.)*(x_))^(r_.), x_Symbol] :> Dist[1/e, Subst[Int[(k*(x/d))^r*(a + b*Log[c*x^n])^p*(f + g*Lo
g[h*((e*i - d*j)/e + j*(x/e))^m]), x], x, d + e*x], x] /; FreeQ[{a, b, c, d, e, f, g, h, i, j, k, l, n, p, r},
 x] && EqQ[e*k - d*l, 0]

Rule 6724

Int[PolyLog[n_, (c_.)*((a_.) + (b_.)*(x_))^(p_.)]/((d_.) + (e_.)*(x_)), x_Symbol] :> Simp[PolyLog[n + 1, c*(a
+ b*x)^p]/(e*p), x] /; FreeQ[{a, b, c, d, e, n, p}, x] && EqQ[b*d, a*e]

Rubi steps

\begin {align*} \int \frac {\left (a+b \log \left (c (d+e x)^n\right )\right )^4}{(f+g x)^2} \, dx &=\frac {(d+e x) \left (a+b \log \left (c (d+e x)^n\right )\right )^4}{(e f-d g) (f+g x)}-\frac {(4 b e n) \int \frac {\left (a+b \log \left (c (d+e x)^n\right )\right )^3}{f+g x} \, dx}{e f-d g}\\ &=\frac {(d+e x) \left (a+b \log \left (c (d+e x)^n\right )\right )^4}{(e f-d g) (f+g x)}-\frac {4 b e n \left (a+b \log \left (c (d+e x)^n\right )\right )^3 \log \left (\frac {e (f+g x)}{e f-d g}\right )}{g (e f-d g)}+\frac {\left (12 b^2 e^2 n^2\right ) \int \frac {\left (a+b \log \left (c (d+e x)^n\right )\right )^2 \log \left (\frac {e (f+g x)}{e f-d g}\right )}{d+e x} \, dx}{g (e f-d g)}\\ &=\frac {(d+e x) \left (a+b \log \left (c (d+e x)^n\right )\right )^4}{(e f-d g) (f+g x)}-\frac {4 b e n \left (a+b \log \left (c (d+e x)^n\right )\right )^3 \log \left (\frac {e (f+g x)}{e f-d g}\right )}{g (e f-d g)}+\frac {\left (12 b^2 e n^2\right ) \text {Subst}\left (\int \frac {\left (a+b \log \left (c x^n\right )\right )^2 \log \left (\frac {e \left (\frac {e f-d g}{e}+\frac {g x}{e}\right )}{e f-d g}\right )}{x} \, dx,x,d+e x\right )}{g (e f-d g)}\\ &=\frac {(d+e x) \left (a+b \log \left (c (d+e x)^n\right )\right )^4}{(e f-d g) (f+g x)}-\frac {4 b e n \left (a+b \log \left (c (d+e x)^n\right )\right )^3 \log \left (\frac {e (f+g x)}{e f-d g}\right )}{g (e f-d g)}-\frac {12 b^2 e n^2 \left (a+b \log \left (c (d+e x)^n\right )\right )^2 \text {Li}_2\left (-\frac {g (d+e x)}{e f-d g}\right )}{g (e f-d g)}+\frac {\left (24 b^3 e n^3\right ) \text {Subst}\left (\int \frac {\left (a+b \log \left (c x^n\right )\right ) \text {Li}_2\left (-\frac {g x}{e f-d g}\right )}{x} \, dx,x,d+e x\right )}{g (e f-d g)}\\ &=\frac {(d+e x) \left (a+b \log \left (c (d+e x)^n\right )\right )^4}{(e f-d g) (f+g x)}-\frac {4 b e n \left (a+b \log \left (c (d+e x)^n\right )\right )^3 \log \left (\frac {e (f+g x)}{e f-d g}\right )}{g (e f-d g)}-\frac {12 b^2 e n^2 \left (a+b \log \left (c (d+e x)^n\right )\right )^2 \text {Li}_2\left (-\frac {g (d+e x)}{e f-d g}\right )}{g (e f-d g)}+\frac {24 b^3 e n^3 \left (a+b \log \left (c (d+e x)^n\right )\right ) \text {Li}_3\left (-\frac {g (d+e x)}{e f-d g}\right )}{g (e f-d g)}-\frac {\left (24 b^4 e n^4\right ) \text {Subst}\left (\int \frac {\text {Li}_3\left (-\frac {g x}{e f-d g}\right )}{x} \, dx,x,d+e x\right )}{g (e f-d g)}\\ &=\frac {(d+e x) \left (a+b \log \left (c (d+e x)^n\right )\right )^4}{(e f-d g) (f+g x)}-\frac {4 b e n \left (a+b \log \left (c (d+e x)^n\right )\right )^3 \log \left (\frac {e (f+g x)}{e f-d g}\right )}{g (e f-d g)}-\frac {12 b^2 e n^2 \left (a+b \log \left (c (d+e x)^n\right )\right )^2 \text {Li}_2\left (-\frac {g (d+e x)}{e f-d g}\right )}{g (e f-d g)}+\frac {24 b^3 e n^3 \left (a+b \log \left (c (d+e x)^n\right )\right ) \text {Li}_3\left (-\frac {g (d+e x)}{e f-d g}\right )}{g (e f-d g)}-\frac {24 b^4 e n^4 \text {Li}_4\left (-\frac {g (d+e x)}{e f-d g}\right )}{g (e f-d g)}\\ \end {align*}

________________________________________________________________________________________

Mathematica [B] Leaf count is larger than twice the leaf count of optimal. \(531\) vs. \(2(248)=496\).
time = 0.47, size = 531, normalized size = 2.14 \begin {gather*} \frac {-\left ((e f-d g) \left (a-b n \log (d+e x)+b \log \left (c (d+e x)^n\right )\right )^4\right )+4 b n \left (a-b n \log (d+e x)+b \log \left (c (d+e x)^n\right )\right )^3 \left (g (d+e x) \log (d+e x)-e (f+g x) \log \left (\frac {e (f+g x)}{e f-d g}\right )\right )+6 b^2 n^2 \left (a-b n \log (d+e x)+b \log \left (c (d+e x)^n\right )\right )^2 \left (\log (d+e x) \left (g (d+e x) \log (d+e x)-2 e (f+g x) \log \left (\frac {e (f+g x)}{e f-d g}\right )\right )-2 e (f+g x) \text {Li}_2\left (\frac {g (d+e x)}{-e f+d g}\right )\right )+4 b^3 n^3 \left (a-b n \log (d+e x)+b \log \left (c (d+e x)^n\right )\right ) \left (\log ^2(d+e x) \left (g (d+e x) \log (d+e x)-3 e (f+g x) \log \left (\frac {e (f+g x)}{e f-d g}\right )\right )-6 e (f+g x) \log (d+e x) \text {Li}_2\left (\frac {g (d+e x)}{-e f+d g}\right )+6 e (f+g x) \text {Li}_3\left (\frac {g (d+e x)}{-e f+d g}\right )\right )+b^4 n^4 \left (g (d+e x) \log ^4(d+e x)-4 e (f+g x) \log ^3(d+e x) \log \left (\frac {e (f+g x)}{e f-d g}\right )-12 e (f+g x) \log ^2(d+e x) \text {Li}_2\left (\frac {g (d+e x)}{-e f+d g}\right )+24 e (f+g x) \log (d+e x) \text {Li}_3\left (\frac {g (d+e x)}{-e f+d g}\right )-24 e (f+g x) \text {Li}_4\left (\frac {g (d+e x)}{-e f+d g}\right )\right )}{g (e f-d g) (f+g x)} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(a + b*Log[c*(d + e*x)^n])^4/(f + g*x)^2,x]

[Out]

(-((e*f - d*g)*(a - b*n*Log[d + e*x] + b*Log[c*(d + e*x)^n])^4) + 4*b*n*(a - b*n*Log[d + e*x] + b*Log[c*(d + e
*x)^n])^3*(g*(d + e*x)*Log[d + e*x] - e*(f + g*x)*Log[(e*(f + g*x))/(e*f - d*g)]) + 6*b^2*n^2*(a - b*n*Log[d +
 e*x] + b*Log[c*(d + e*x)^n])^2*(Log[d + e*x]*(g*(d + e*x)*Log[d + e*x] - 2*e*(f + g*x)*Log[(e*(f + g*x))/(e*f
 - d*g)]) - 2*e*(f + g*x)*PolyLog[2, (g*(d + e*x))/(-(e*f) + d*g)]) + 4*b^3*n^3*(a - b*n*Log[d + e*x] + b*Log[
c*(d + e*x)^n])*(Log[d + e*x]^2*(g*(d + e*x)*Log[d + e*x] - 3*e*(f + g*x)*Log[(e*(f + g*x))/(e*f - d*g)]) - 6*
e*(f + g*x)*Log[d + e*x]*PolyLog[2, (g*(d + e*x))/(-(e*f) + d*g)] + 6*e*(f + g*x)*PolyLog[3, (g*(d + e*x))/(-(
e*f) + d*g)]) + b^4*n^4*(g*(d + e*x)*Log[d + e*x]^4 - 4*e*(f + g*x)*Log[d + e*x]^3*Log[(e*(f + g*x))/(e*f - d*
g)] - 12*e*(f + g*x)*Log[d + e*x]^2*PolyLog[2, (g*(d + e*x))/(-(e*f) + d*g)] + 24*e*(f + g*x)*Log[d + e*x]*Pol
yLog[3, (g*(d + e*x))/(-(e*f) + d*g)] - 24*e*(f + g*x)*PolyLog[4, (g*(d + e*x))/(-(e*f) + d*g)]))/(g*(e*f - d*
g)*(f + g*x))

________________________________________________________________________________________

Maple [C] Result contains higher order function than in optimal. Order 9 vs. order 4.
time = 1.70, size = 21740, normalized size = 87.66

method result size
risch \(\text {Expression too large to display}\) \(21740\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+b*ln(c*(e*x+d)^n))^4/(g*x+f)^2,x,method=_RETURNVERBOSE)

[Out]

result too large to display

________________________________________________________________________________________

Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*log(c*(e*x+d)^n))^4/(g*x+f)^2,x, algorithm="maxima")

[Out]

4*a^3*b*n*(log(g*x + f)/(d*g^2 - f*g*e) - log(x*e + d)/(d*g^2 - f*g*e))*e - b^4*log((x*e + d)^n)^4/(g^2*x + f*
g) - 4*a^3*b*log((x*e + d)^n*c)/(g^2*x + f*g) - a^4/(g^2*x + f*g) + integrate((b^4*d*g*log(c)^4 + 4*a*b^3*d*g*
log(c)^3 + 6*a^2*b^2*d*g*log(c)^2 + 4*(b^4*f*n*e + b^4*d*g*log(c) + a*b^3*d*g + ((g*n + g*log(c))*b^4 + a*b^3*
g)*x*e)*log((x*e + d)^n)^3 + (b^4*g*log(c)^4 + 4*a*b^3*g*log(c)^3 + 6*a^2*b^2*g*log(c)^2)*x*e + 6*(b^4*d*g*log
(c)^2 + 2*a*b^3*d*g*log(c) + a^2*b^2*d*g + (b^4*g*log(c)^2 + 2*a*b^3*g*log(c) + a^2*b^2*g)*x*e)*log((x*e + d)^
n)^2 + 4*(b^4*d*g*log(c)^3 + 3*a*b^3*d*g*log(c)^2 + 3*a^2*b^2*d*g*log(c) + (b^4*g*log(c)^3 + 3*a*b^3*g*log(c)^
2 + 3*a^2*b^2*g*log(c))*x*e)*log((x*e + d)^n))/(g^3*x^3*e + d*f^2*g + (d*g^3 + 2*f*g^2*e)*x^2 + (2*d*f*g^2 + f
^2*g*e)*x), x)

________________________________________________________________________________________

Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*log(c*(e*x+d)^n))^4/(g*x+f)^2,x, algorithm="fricas")

[Out]

integral((b^4*log((x*e + d)^n*c)^4 + 4*a*b^3*log((x*e + d)^n*c)^3 + 6*a^2*b^2*log((x*e + d)^n*c)^2 + 4*a^3*b*l
og((x*e + d)^n*c) + a^4)/(g^2*x^2 + 2*f*g*x + f^2), x)

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {\left (a + b \log {\left (c \left (d + e x\right )^{n} \right )}\right )^{4}}{\left (f + g x\right )^{2}}\, dx \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*ln(c*(e*x+d)**n))**4/(g*x+f)**2,x)

[Out]

Integral((a + b*log(c*(d + e*x)**n))**4/(f + g*x)**2, x)

________________________________________________________________________________________

Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*log(c*(e*x+d)^n))^4/(g*x+f)^2,x, algorithm="giac")

[Out]

integrate((b*log((x*e + d)^n*c) + a)^4/(g*x + f)^2, x)

________________________________________________________________________________________

Mupad [F]
time = 0.00, size = -1, normalized size = -0.00 \begin {gather*} \int \frac {{\left (a+b\,\ln \left (c\,{\left (d+e\,x\right )}^n\right )\right )}^4}{{\left (f+g\,x\right )}^2} \,d x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a + b*log(c*(d + e*x)^n))^4/(f + g*x)^2,x)

[Out]

int((a + b*log(c*(d + e*x)^n))^4/(f + g*x)^2, x)

________________________________________________________________________________________